3.235 \(\int \sec ^3(c+d x) (a \sin (c+d x)+b \tan (c+d x)) \, dx\)

Optimal. Leaf size=33 \[ \frac{a \sec ^2(c+d x)}{2 d}+\frac{b \sec ^3(c+d x)}{3 d} \]

[Out]

(a*Sec[c + d*x]^2)/(2*d) + (b*Sec[c + d*x]^3)/(3*d)

________________________________________________________________________________________

Rubi [A]  time = 0.0569483, antiderivative size = 33, normalized size of antiderivative = 1., number of steps used = 6, number of rules used = 4, integrand size = 26, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.154, Rules used = {4377, 12, 2606, 30} \[ \frac{a \sec ^2(c+d x)}{2 d}+\frac{b \sec ^3(c+d x)}{3 d} \]

Antiderivative was successfully verified.

[In]

Int[Sec[c + d*x]^3*(a*Sin[c + d*x] + b*Tan[c + d*x]),x]

[Out]

(a*Sec[c + d*x]^2)/(2*d) + (b*Sec[c + d*x]^3)/(3*d)

Rule 4377

Int[(u_)*((v_) + (d_.)*(F_)[(c_.)*((a_.) + (b_.)*(x_))]^(n_.)), x_Symbol] :> With[{e = FreeFactors[Cos[c*(a +
b*x)], x]}, Int[ActivateTrig[u*v], x] + Dist[d, Int[ActivateTrig[u]*Sin[c*(a + b*x)]^n, x], x] /; FunctionOfQ[
Cos[c*(a + b*x)]/e, u, x]] /; FreeQ[{a, b, c, d}, x] &&  !FreeQ[v, x] && IntegerQ[(n - 1)/2] && NonsumQ[u] &&
(EqQ[F, Sin] || EqQ[F, sin])

Rule 12

Int[(a_)*(u_), x_Symbol] :> Dist[a, Int[u, x], x] /; FreeQ[a, x] &&  !MatchQ[u, (b_)*(v_) /; FreeQ[b, x]]

Rule 2606

Int[((a_.)*sec[(e_.) + (f_.)*(x_)])^(m_.)*((b_.)*tan[(e_.) + (f_.)*(x_)])^(n_.), x_Symbol] :> Dist[a/f, Subst[
Int[(a*x)^(m - 1)*(-1 + x^2)^((n - 1)/2), x], x, Sec[e + f*x]], x] /; FreeQ[{a, e, f, m}, x] && IntegerQ[(n -
1)/2] &&  !(IntegerQ[m/2] && LtQ[0, m, n + 1])

Rule 30

Int[(x_)^(m_.), x_Symbol] :> Simp[x^(m + 1)/(m + 1), x] /; FreeQ[m, x] && NeQ[m, -1]

Rubi steps

\begin{align*} \int \sec ^3(c+d x) (a \sin (c+d x)+b \tan (c+d x)) \, dx &=a \int \sec ^2(c+d x) \tan (c+d x) \, dx+\int b \sec ^3(c+d x) \tan (c+d x) \, dx\\ &=b \int \sec ^3(c+d x) \tan (c+d x) \, dx+\frac{a \operatorname{Subst}(\int x \, dx,x,\sec (c+d x))}{d}\\ &=\frac{a \sec ^2(c+d x)}{2 d}+\frac{b \operatorname{Subst}\left (\int x^2 \, dx,x,\sec (c+d x)\right )}{d}\\ &=\frac{a \sec ^2(c+d x)}{2 d}+\frac{b \sec ^3(c+d x)}{3 d}\\ \end{align*}

Mathematica [A]  time = 0.0225567, size = 33, normalized size = 1. \[ \frac{a \sec ^2(c+d x)}{2 d}+\frac{b \sec ^3(c+d x)}{3 d} \]

Antiderivative was successfully verified.

[In]

Integrate[Sec[c + d*x]^3*(a*Sin[c + d*x] + b*Tan[c + d*x]),x]

[Out]

(a*Sec[c + d*x]^2)/(2*d) + (b*Sec[c + d*x]^3)/(3*d)

________________________________________________________________________________________

Maple [A]  time = 0.033, size = 28, normalized size = 0.9 \begin{align*}{\frac{1}{d} \left ({\frac{ \left ( \sec \left ( dx+c \right ) \right ) ^{3}b}{3}}+{\frac{a \left ( \sec \left ( dx+c \right ) \right ) ^{2}}{2}} \right ) } \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sec(d*x+c)^3*(a*sin(d*x+c)+b*tan(d*x+c)),x)

[Out]

1/d*(1/3*sec(d*x+c)^3*b+1/2*a*sec(d*x+c)^2)

________________________________________________________________________________________

Maxima [A]  time = 1.05449, size = 43, normalized size = 1.3 \begin{align*} -\frac{\frac{3 \, a}{\sin \left (d x + c\right )^{2} - 1} - \frac{2 \, b}{\cos \left (d x + c\right )^{3}}}{6 \, d} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(d*x+c)^3*(a*sin(d*x+c)+b*tan(d*x+c)),x, algorithm="maxima")

[Out]

-1/6*(3*a/(sin(d*x + c)^2 - 1) - 2*b/cos(d*x + c)^3)/d

________________________________________________________________________________________

Fricas [A]  time = 0.471809, size = 66, normalized size = 2. \begin{align*} \frac{3 \, a \cos \left (d x + c\right ) + 2 \, b}{6 \, d \cos \left (d x + c\right )^{3}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(d*x+c)^3*(a*sin(d*x+c)+b*tan(d*x+c)),x, algorithm="fricas")

[Out]

1/6*(3*a*cos(d*x + c) + 2*b)/(d*cos(d*x + c)^3)

________________________________________________________________________________________

Sympy [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \left (a \sin{\left (c + d x \right )} + b \tan{\left (c + d x \right )}\right ) \sec ^{3}{\left (c + d x \right )}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(d*x+c)**3*(a*sin(d*x+c)+b*tan(d*x+c)),x)

[Out]

Integral((a*sin(c + d*x) + b*tan(c + d*x))*sec(c + d*x)**3, x)

________________________________________________________________________________________

Giac [B]  time = 1.16724, size = 131, normalized size = 3.97 \begin{align*} \frac{2 \,{\left (b - \frac{3 \, a{\left (\cos \left (d x + c\right ) - 1\right )}}{\cos \left (d x + c\right ) + 1} - \frac{3 \, a{\left (\cos \left (d x + c\right ) - 1\right )}^{2}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{2}} + \frac{3 \, b{\left (\cos \left (d x + c\right ) - 1\right )}^{2}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{2}}\right )}}{3 \, d{\left (\frac{\cos \left (d x + c\right ) - 1}{\cos \left (d x + c\right ) + 1} + 1\right )}^{3}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(d*x+c)^3*(a*sin(d*x+c)+b*tan(d*x+c)),x, algorithm="giac")

[Out]

2/3*(b - 3*a*(cos(d*x + c) - 1)/(cos(d*x + c) + 1) - 3*a*(cos(d*x + c) - 1)^2/(cos(d*x + c) + 1)^2 + 3*b*(cos(
d*x + c) - 1)^2/(cos(d*x + c) + 1)^2)/(d*((cos(d*x + c) - 1)/(cos(d*x + c) + 1) + 1)^3)